# coding:utf-8
# filename:yangsy.py

from selenium import webdriver
import time

url = 'https://test.rabbitpre.com/'
driver = webdriver.Chrome()
driver.get(url)
driver.maximize_window()

sign_btn = driver.find_element_by_xpath('//*[@id="g-j-signin-btn"]')
sign_btn.click()
# driver.find_element_by_css_selector('').click()
login_sso = driver.find_element_by_id('sso')
driver.switch_to.frame(login_sso)
driver.find_element_by_xpath('/html/body/div[1]/div/div[2]/div[1]/span[2]')
time.sleep(2)
driver.find_element_by_xpath('//span[@data-type="tuzhan"]').click()
driver.find_element_by_xpath('/html/body/div[1]/div/div[2]/div[3]/div[1]/input').send_keys('xxx')
driver.find_element_by_xpath('/html/body/div[1]/div/div[2]/div[3]/div[2]/input').send_keys('xxx')
driver.find_element_by_xpath('/html/body/div[1]/div/div[2]/div[3]/button').click()
time.sleep(3)

driver.quit()